To avoid the aforementioned problems, classes may be defined using the 'direct' specifier. In this case the implementation of pointers to objects is NOT a handle, but is simply a pointer. Using direct classes is also occasionally preferable to avoid overloading the Macintosh memory manager with many small objects.
The drawbacks are: (1) the Macintosh memory management routines have less freedom in dynamically restructuring memory since the objects may not be moved, (2) the new() and delete() functions are not defined for 'direct' objects.
The second consideration listed above may be overcome by using the standard malloc() and free() C memory allocation functions* in place of new() and delete(), and by declaring this memory as a direct object using the blessD() function in the oops library. For example, suppose the Person class is 'direct', then a Person object may be declared, allocated, and deallocated as follows: